<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>{$article.title}</title>
<link rel="stylesheet" href="__ROOT__/Public/index/myindex.css" media="screen" type="text/css" />
<script src="http://apps.bdimg.com/libs/jquery/2.1.1/jquery.min.js"></script>
<link rel="stylesheet" href="__ROOT__/Public/bootstrap/css/bootstrap.min.css">
<style>

.bottom{
	float:right;
	width:100%;

}
textarea{
	width:100%;
	border-radius: 4px;
}
.comment{
	display:none;
	background:#fff;
	padding:5px;
	border-radius: 4px;
	margin:5px;
}
.replycomment{
	float:right;
	cursor:pointer;
}
#reply{
		cursor:pointer;
}
.items{
	padding:2px;
}
.article_title{
	font-size:16px;
}
</style>
</head>
<body>
<include file="Public/nav"/>
<include file="Public/menu_left"/>
<div class="article">
<div class="panel panel-default">
  <div class="panel-heading"><b class="">{$article.title} </b><span class="posttime">发表时期：{$article.time}</span></div>
  <div class="panel-body" >
  {$article.content}  <div style="float:right"><span class="label label-default">分类:{$article.type}</span><span style="color:green"></div>
  </div>

  </div>

    <div class="bottom">
        <volist id="vo" name="articlecomment">
    <div class="comment">
	<span style="color:green">{$vo.username}:</span>
    {$vo.content}
	<div class="replycomment" onclick="replycomment('{$vo.id}','{$vo.username}');">
	回复
	</div>
    </div>
        </volist>
    <p class="items">阅读({$article.veiw})|<span id="reply">评论({$article.replynums})</span>|<a href="__APP__/Home/Index/edit.html?id={$article.id}">编辑</a>|<a href="__APP__/Admin/Index/delarticle.html?id={$article.id}">删除</a></p>
  <div class="reply">
  <form action="__URL__/reply"method="post" onkeydown="if(event.ctrlKey&&event.keyCode==13)this.submit()">
  <p><textarea name="content" id="comment"></textarea></p>
  <input type="hidden" name="articleid" value="{$article.id}">
    <input type="hidden" name="username" value="{$Think.session.username}">
  <p><input type="submit"value="发表评论" class="btn"></p>
  </form>
  </div>
  </div>
<script>
$("#reply").click(function(){
	$(".comment").toggle(300);
});

function replycomment(id,username){
	$("#comment").val("@"+username+": ");
}
	

</script>
</body>
</html>